package com.huilian.tool.applet.wechat.service;

import java.io.UnsupportedEncodingException;
import java.security.InvalidAlgorithmParameterException;

public interface WeChatAppletService {

    String getAccessToken(String redisKey) throws Exception;

    String getAccessToken(String appId, String appSecret, String redisKey) throws Exception;

    String getJsCode2Session(String code);

    String getJsCode2Session(String code, String appId, String appSecret);

    String getUserInfoAndDecode(String iv, String encryptedData, String sessionKey) throws InvalidAlgorithmParameterException, UnsupportedEncodingException, Exception;

    String getUserPhoneNumber(String code, String redisKey) throws Exception;

    String getUserPhoneNumber(String code, String appId, String appSecret, String redisKey) throws Exception;
}
